package moco.blatt3.intents;

import moco.blatt3.R;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.widget.TextView;


public class AnotherActivity extends Activity {

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.another_activity);
        
        Bundle extras  = getIntent().getExtras();
        String intent_var = extras.getString("intent_var");
        
        // Toast.makeText(getApplicationContext(), intent_var, Toast.LENGTH_LONG).show();
        
        TextView tv = (TextView) findViewById(R.id.tv);
        tv.setText(intent_var);
       
    }
    
    public void goBack(){
    	Intent i = new Intent();
    	i.setClassName("moco.blatt3.intents", "moco.blatt3.intents.MainIntents");
    	startActivity(i);
    	// super.onBackPressed();
    }
    /*
    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        getMenuInflater().inflate(R.menu., menu);
        return true;
    }
    */
}
